package com.example.normaldemo;

import androidx.appcompat.app.AppCompatActivity;

import android.content.Intent;
import android.os.Bundle;
import android.view.View;
import android.widget.Button;

public class MainActivity extends AppCompatActivity {

    private Button mNumberBtn, mFragmentBtn,mJobButton,mDragButton;

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_main);
        mNumberBtn = findViewById(R.id.btn_number);
        mFragmentBtn = findViewById(R.id.btn_fragment);
        mJobButton = findViewById(R.id.btn_JobScheduler);
        mDragButton = findViewById(R.id.btn_DragLocationView);
        mNumberBtn.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View view) {
                startActivity(new Intent(MainActivity.this,NumberActivity.class));
            }
        });
        mFragmentBtn.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View view) {
                startActivity(new Intent(MainActivity.this,FragmentActivity.class));
            }
        });
        mJobButton.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View view) {
                startActivity(new Intent(MainActivity.this,JobActivity.class));
            }
        });
        mDragButton.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View view) {
                startActivity(new Intent(MainActivity.this, DragActivity.class));
            }
        });
    }
}